package com.oywy.rbac.entity;

import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;
import org.springframework.security.core.GrantedAuthority;

import javax.persistence.Entity;
import javax.persistence.ManyToMany;
import java.util.Collection;

/**
 * 权限
 *
 * @author oywy
 * @date 2018/10/22
 */
@Entity
@Data
public class Authority extends BaseEntity implements GrantedAuthority {
    private String name;
    private String url;
    private String method;
    private boolean menu;

    @Override
    public String getAuthority() {
        return name;
    }

}
